package com.corona.game;

import com.badlogic.gdx.graphics.g2d.Sprite;
import com.corona.Game;

/* compiled from: Player.java */
/* loaded from: pokewilds.jar:com/pkmngen/game/DrawPlayerLower.class */
public class DrawPlayerLower extends Action {
    public Action.Layer layer = Action.Layer.map_130;
    Sprite spritePart = new Sprite();
    int fishingOffsetX = 0;
    int fishingOffsetY = 0;

    public DrawPlayerLower() {
        super(new Object[0]);
    }

    @Override // com.corona.game.Action
    public Action.Layer getLayer() {
        return this.layer;
    }

    @Override // com.corona.game.Action
    public void step(Game game) {
        if (!game.player.isSitting && !game.player.isSleeping && !game.player.currFieldMove.equals("FLY") && !game.player.currFieldMove.equals("SURF")) {
            this.spritePart.set(game.player.currSprite);
            this.fishingOffsetX = 0;
            this.fishingOffsetY = 0;
            if (game.player.isFishing) {
                if (game.player.dirFacing.equals("left")) {
                    this.fishingOffsetX = -8;
                } else if (game.player.dirFacing.equals("down")) {
                    this.fishingOffsetY = -8;
                }
            }
            this.spritePart.setRegionY(game.player.spriteOffsetY + 8);
            this.spritePart.setRegionHeight(((int) this.spritePart.getHeight()) - 8);
            game.mapBatch.draw(this.spritePart, game.player.position.x + ((float) this.fishingOffsetX), game.player.position.y + 4.0f + ((float) DrawPlayerUpper.pokemonOffsetY) + ((float) this.fishingOffsetY));
        }
    }
}
